<?php 
define('MODULE_NAME','List');

$actions = array('index','submit','doread', 'robot', 'staff', 'workplan', 'plan', 'lists');
$action = 'index';

if(isset($_REQUEST['action']))
{
	$action = strtolower($_REQUEST['action']);
	if(!in_array($action,$actions))
		$action = 'index';
}

define('ACTION_NAME',$action);

require dirname(__FILE__).'/core/fanwe.php';
$fanwe = &FanweService::instance();
$fanwe->initialize();
require fimport('module/list');

if($_FANWE['uid'] == 0)
	fHeader("location: ".FU('user/login'));

$_FANWE['nav_title'] = lang('common','list');

switch(ACTION_NAME)
{
	case 'index':
		ListModule::index();
	break;
		case 'submit':
		ListModule::submit();
	break;
	case 'doread':
		ListModule::doread();
	break;
	case 'robot':
		ListModule::robot();
	break;
	case 'staff':
		ListModule::staff();
	break;
	case 'workplan':
		ListModule::workplan();
	break;
	case 'plan':
		ListModule::plan();
	break;
	case 'lists':
		ListModule::lists();
	break;
}
